3.13.31 \(\int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx\) [1231]

3.13.31.1 Optimal result
3.13.31.2 Mathematica [A] (verified)
3.13.31.3 Rubi [A] (warning: unable to verify)
3.13.31.4 Maple [B] (verified)
3.13.31.5 Fricas [B] (verification not implemented)
3.13.31.6 Sympy [F]
3.13.31.7 Maxima [F(-2)]
3.13.31.8 Giac [F(-1)]
3.13.31.9 Mupad [B] (verification not implemented)

3.13.31.1 Optimal result

Integrand size = 25, antiderivative size = 122 \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=-\frac {(i a+b) \sqrt {c-i d} \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c-i d}}\right )}{f}+\frac {(i a-b) \sqrt {c+i d} \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c+i d}}\right )}{f}+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f} \]

output
-(I*a+b)*arctanh((c+d*tan(f*x+e))^(1/2)/(c-I*d)^(1/2))*(c-I*d)^(1/2)/f+(I* 
a-b)*arctanh((c+d*tan(f*x+e))^(1/2)/(c+I*d)^(1/2))*(c+I*d)^(1/2)/f+2*b*(c+ 
d*tan(f*x+e))^(1/2)/f
 
3.13.31.2 Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 120, normalized size of antiderivative = 0.98 \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=\frac {-i (a-i b) \sqrt {c-i d} \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c-i d}}\right )+i (a+i b) \sqrt {c+i d} \text {arctanh}\left (\frac {\sqrt {c+d \tan (e+f x)}}{\sqrt {c+i d}}\right )+2 b \sqrt {c+d \tan (e+f x)}}{f} \]

input
Integrate[(a + b*Tan[e + f*x])*Sqrt[c + d*Tan[e + f*x]],x]
 
output
((-I)*(a - I*b)*Sqrt[c - I*d]*ArcTanh[Sqrt[c + d*Tan[e + f*x]]/Sqrt[c - I* 
d]] + I*(a + I*b)*Sqrt[c + I*d]*ArcTanh[Sqrt[c + d*Tan[e + f*x]]/Sqrt[c + 
I*d]] + 2*b*Sqrt[c + d*Tan[e + f*x]])/f
 
3.13.31.3 Rubi [A] (warning: unable to verify)

Time = 0.58 (sec) , antiderivative size = 103, normalized size of antiderivative = 0.84, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.360, Rules used = {3042, 4011, 3042, 4022, 3042, 4020, 25, 73, 221}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)}dx\)

\(\Big \downarrow \) 4011

\(\displaystyle \int \frac {a c-b d+(b c+a d) \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {a c-b d+(b c+a d) \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 4022

\(\displaystyle \frac {1}{2} (a+i b) (c+i d) \int \frac {1-i \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx+\frac {1}{2} (a-i b) (c-i d) \int \frac {i \tan (e+f x)+1}{\sqrt {c+d \tan (e+f x)}}dx+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 3042

\(\displaystyle \frac {1}{2} (a+i b) (c+i d) \int \frac {1-i \tan (e+f x)}{\sqrt {c+d \tan (e+f x)}}dx+\frac {1}{2} (a-i b) (c-i d) \int \frac {i \tan (e+f x)+1}{\sqrt {c+d \tan (e+f x)}}dx+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 4020

\(\displaystyle \frac {i (a-i b) (c-i d) \int -\frac {1}{(1-i \tan (e+f x)) \sqrt {c+d \tan (e+f x)}}d(i \tan (e+f x))}{2 f}-\frac {i (a+i b) (c+i d) \int -\frac {1}{(i \tan (e+f x)+1) \sqrt {c+d \tan (e+f x)}}d(-i \tan (e+f x))}{2 f}+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 25

\(\displaystyle -\frac {i (a-i b) (c-i d) \int \frac {1}{(1-i \tan (e+f x)) \sqrt {c+d \tan (e+f x)}}d(i \tan (e+f x))}{2 f}+\frac {i (a+i b) (c+i d) \int \frac {1}{(i \tan (e+f x)+1) \sqrt {c+d \tan (e+f x)}}d(-i \tan (e+f x))}{2 f}+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 73

\(\displaystyle \frac {(a+i b) (c+i d) \int \frac {1}{-\frac {i \tan ^2(e+f x)}{d}-\frac {i c}{d}+1}d\sqrt {c+d \tan (e+f x)}}{d f}+\frac {(a-i b) (c-i d) \int \frac {1}{\frac {i \tan ^2(e+f x)}{d}+\frac {i c}{d}+1}d\sqrt {c+d \tan (e+f x)}}{d f}+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

\(\Big \downarrow \) 221

\(\displaystyle \frac {(a-i b) \sqrt {c-i d} \arctan \left (\frac {\tan (e+f x)}{\sqrt {c-i d}}\right )}{f}+\frac {(a+i b) \sqrt {c+i d} \arctan \left (\frac {\tan (e+f x)}{\sqrt {c+i d}}\right )}{f}+\frac {2 b \sqrt {c+d \tan (e+f x)}}{f}\)

input
Int[(a + b*Tan[e + f*x])*Sqrt[c + d*Tan[e + f*x]],x]
 
output
((a - I*b)*Sqrt[c - I*d]*ArcTan[Tan[e + f*x]/Sqrt[c - I*d]])/f + ((a + I*b 
)*Sqrt[c + I*d]*ArcTan[Tan[e + f*x]/Sqrt[c + I*d]])/f + (2*b*Sqrt[c + d*Ta 
n[e + f*x]])/f
 

3.13.31.3.1 Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 73
Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[ 
{p = Denominator[m]}, Simp[p/b   Subst[Int[x^(p*(m + 1) - 1)*(c - a*(d/b) + 
 d*(x^p/b))^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] && Lt 
Q[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntL 
inearQ[a, b, c, d, m, n, x]
 

rule 221
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x 
/Rt[-a/b, 2]], x] /; FreeQ[{a, b}, x] && NegQ[a/b]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4011
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + 
 (f_.)*(x_)]), x_Symbol] :> Simp[d*((a + b*Tan[e + f*x])^m/(f*m)), x] + Int 
[(a + b*Tan[e + f*x])^(m - 1)*Simp[a*c - b*d + (b*c + a*d)*Tan[e + f*x], x] 
, x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 + b^2, 
 0] && GtQ[m, 0]
 

rule 4020
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_) + (d_.)*tan[(e_.) + 
(f_.)*(x_)]), x_Symbol] :> Simp[c*(d/f)   Subst[Int[(a + (b/d)*x)^m/(d^2 + 
c*x), x], x, d*Tan[e + f*x]], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[ 
b*c - a*d, 0] && NeQ[a^2 + b^2, 0] && EqQ[c^2 + d^2, 0]
 

rule 4022
Int[((a_.) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*tan[(e_.) + 
 (f_.)*(x_)]), x_Symbol] :> Simp[(c + I*d)/2   Int[(a + b*Tan[e + f*x])^m*( 
1 - I*Tan[e + f*x]), x], x] + Simp[(c - I*d)/2   Int[(a + b*Tan[e + f*x])^m 
*(1 + I*Tan[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && NeQ[b*c 
 - a*d, 0] && NeQ[a^2 + b^2, 0] && NeQ[c^2 + d^2, 0] &&  !IntegerQ[m]
 
3.13.31.4 Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(811\) vs. \(2(102)=204\).

Time = 0.91 (sec) , antiderivative size = 812, normalized size of antiderivative = 6.66

method result size
parts \(-\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}+\frac {d \arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}+\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}-\frac {d \arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}-\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}+\frac {b \left (2 \sqrt {c +d \tan \left (f x +e \right )}-\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right )}{4}+\frac {\left (-\sqrt {c^{2}+d^{2}}+c \right ) \arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right )}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right )}{4}+\frac {\left (\sqrt {c^{2}+d^{2}}-c \right ) \arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right )}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right )}{f}\) \(812\)
derivativedivides \(\frac {2 b \sqrt {c +d \tan \left (f x +e \right )}}{f}-\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}+\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}-\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, b}{4 f}-\frac {\arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) \sqrt {c^{2}+d^{2}}\, b}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {d \arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) b c}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}-\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}+\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, b}{4 f}+\frac {\arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) \sqrt {c^{2}+d^{2}}\, b}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}-\frac {d \arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}-\frac {\arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) b c}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\) \(968\)
default \(\frac {2 b \sqrt {c +d \tan \left (f x +e \right )}}{f}-\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}+\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}-\frac {\ln \left (d \tan \left (f x +e \right )+c +\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}+\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, b}{4 f}-\frac {\arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) \sqrt {c^{2}+d^{2}}\, b}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {d \arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\arctan \left (\frac {2 \sqrt {c +d \tan \left (f x +e \right )}+\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) b c}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}+\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, \sqrt {c^{2}+d^{2}}\, a}{4 f d}-\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, a c}{4 f d}+\frac {\ln \left (\sqrt {c +d \tan \left (f x +e \right )}\, \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-d \tan \left (f x +e \right )-c -\sqrt {c^{2}+d^{2}}\right ) \sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}\, b}{4 f}+\frac {\arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) \sqrt {c^{2}+d^{2}}\, b}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}-\frac {d \arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) a}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}-\frac {\arctan \left (\frac {\sqrt {2 \sqrt {c^{2}+d^{2}}+2 c}-2 \sqrt {c +d \tan \left (f x +e \right )}}{\sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\right ) b c}{f \sqrt {2 \sqrt {c^{2}+d^{2}}-2 c}}\) \(968\)

input
int((c+d*tan(f*x+e))^(1/2)*(a+b*tan(f*x+e)),x,method=_RETURNVERBOSE)
 
output
-1/4/f/d*ln(d*tan(f*x+e)+c+(c+d*tan(f*x+e))^(1/2)*(2*(c^2+d^2)^(1/2)+2*c)^ 
(1/2)+(c^2+d^2)^(1/2))*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)*(c^2+d^2)^(1/2)*a+1/f 
*d/(2*(c^2+d^2)^(1/2)-2*c)^(1/2)*arctan((2*(c+d*tan(f*x+e))^(1/2)+(2*(c^2+ 
d^2)^(1/2)+2*c)^(1/2))/(2*(c^2+d^2)^(1/2)-2*c)^(1/2))*a+1/4/f/d*ln(d*tan(f 
*x+e)+c+(c+d*tan(f*x+e))^(1/2)*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)+(c^2+d^2)^(1/ 
2))*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)*a*c+1/4/f/d*ln((c+d*tan(f*x+e))^(1/2)*(2 
*(c^2+d^2)^(1/2)+2*c)^(1/2)-d*tan(f*x+e)-c-(c^2+d^2)^(1/2))*(2*(c^2+d^2)^( 
1/2)+2*c)^(1/2)*(c^2+d^2)^(1/2)*a-1/f*d/(2*(c^2+d^2)^(1/2)-2*c)^(1/2)*arct 
an(((2*(c^2+d^2)^(1/2)+2*c)^(1/2)-2*(c+d*tan(f*x+e))^(1/2))/(2*(c^2+d^2)^( 
1/2)-2*c)^(1/2))*a-1/4/f/d*ln((c+d*tan(f*x+e))^(1/2)*(2*(c^2+d^2)^(1/2)+2* 
c)^(1/2)-d*tan(f*x+e)-c-(c^2+d^2)^(1/2))*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)*a*c 
+b/f*(2*(c+d*tan(f*x+e))^(1/2)-1/4*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)*ln(d*tan( 
f*x+e)+c+(c+d*tan(f*x+e))^(1/2)*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)+(c^2+d^2)^(1 
/2))+(-(c^2+d^2)^(1/2)+c)/(2*(c^2+d^2)^(1/2)-2*c)^(1/2)*arctan((2*(c+d*tan 
(f*x+e))^(1/2)+(2*(c^2+d^2)^(1/2)+2*c)^(1/2))/(2*(c^2+d^2)^(1/2)-2*c)^(1/2 
))+1/4*(2*(c^2+d^2)^(1/2)+2*c)^(1/2)*ln((c+d*tan(f*x+e))^(1/2)*(2*(c^2+d^2 
)^(1/2)+2*c)^(1/2)-d*tan(f*x+e)-c-(c^2+d^2)^(1/2))+((c^2+d^2)^(1/2)-c)/(2* 
(c^2+d^2)^(1/2)-2*c)^(1/2)*arctan(((2*(c^2+d^2)^(1/2)+2*c)^(1/2)-2*(c+d*ta 
n(f*x+e))^(1/2))/(2*(c^2+d^2)^(1/2)-2*c)^(1/2)))
 
3.13.31.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1199 vs. \(2 (97) = 194\).

Time = 0.27 (sec) , antiderivative size = 1199, normalized size of antiderivative = 9.83 \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=\text {Too large to display} \]

input
integrate((c+d*tan(f*x+e))^(1/2)*(a+b*tan(f*x+e)),x, algorithm="fricas")
 
output
-1/2*(f*sqrt((2*a*b*d + f^2*sqrt(-(4*a^2*b^2*c^2 + 4*(a^3*b - a*b^3)*c*d + 
 (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^2)*log(-(2*(a^3*b + 
a*b^3)*c + (a^4 - b^4)*d)*sqrt(d*tan(f*x + e) + c) + (a*f^3*sqrt(-(4*a^2*b 
^2*c^2 + 4*(a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (2*a* 
b^2*c + (a^2*b - b^3)*d)*f)*sqrt((2*a*b*d + f^2*sqrt(-(4*a^2*b^2*c^2 + 4*( 
a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^ 
2)) - f*sqrt((2*a*b*d + f^2*sqrt(-(4*a^2*b^2*c^2 + 4*(a^3*b - a*b^3)*c*d + 
 (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^2)*log(-(2*(a^3*b + 
a*b^3)*c + (a^4 - b^4)*d)*sqrt(d*tan(f*x + e) + c) - (a*f^3*sqrt(-(4*a^2*b 
^2*c^2 + 4*(a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (2*a* 
b^2*c + (a^2*b - b^3)*d)*f)*sqrt((2*a*b*d + f^2*sqrt(-(4*a^2*b^2*c^2 + 4*( 
a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^ 
2)) - f*sqrt((2*a*b*d - f^2*sqrt(-(4*a^2*b^2*c^2 + 4*(a^3*b - a*b^3)*c*d + 
 (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^2)*log(-(2*(a^3*b + 
a*b^3)*c + (a^4 - b^4)*d)*sqrt(d*tan(f*x + e) + c) + (a*f^3*sqrt(-(4*a^2*b 
^2*c^2 + 4*(a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) + (2*a* 
b^2*c + (a^2*b - b^3)*d)*f)*sqrt((2*a*b*d - f^2*sqrt(-(4*a^2*b^2*c^2 + 4*( 
a^3*b - a*b^3)*c*d + (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^ 
2)) + f*sqrt((2*a*b*d - f^2*sqrt(-(4*a^2*b^2*c^2 + 4*(a^3*b - a*b^3)*c*d + 
 (a^4 - 2*a^2*b^2 + b^4)*d^2)/f^4) - (a^2 - b^2)*c)/f^2)*log(-(2*(a^3*b...
 
3.13.31.6 Sympy [F]

\[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=\int \left (a + b \tan {\left (e + f x \right )}\right ) \sqrt {c + d \tan {\left (e + f x \right )}}\, dx \]

input
integrate((c+d*tan(f*x+e))**(1/2)*(a+b*tan(f*x+e)),x)
 
output
Integral((a + b*tan(e + f*x))*sqrt(c + d*tan(e + f*x)), x)
 
3.13.31.7 Maxima [F(-2)]

Exception generated. \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=\text {Exception raised: ValueError} \]

input
integrate((c+d*tan(f*x+e))^(1/2)*(a+b*tan(f*x+e)),x, algorithm="maxima")
 
output
Exception raised: ValueError >> Computation failed since Maxima requested 
additional constraints; using the 'assume' command before evaluation *may* 
 help (example of legal syntax is 'assume(d-c>0)', see `assume?` for more 
details)Is
 
3.13.31.8 Giac [F(-1)]

Timed out. \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=\text {Timed out} \]

input
integrate((c+d*tan(f*x+e))^(1/2)*(a+b*tan(f*x+e)),x, algorithm="giac")
 
output
Timed out
 
3.13.31.9 Mupad [B] (verification not implemented)

Time = 8.92 (sec) , antiderivative size = 845, normalized size of antiderivative = 6.93 \[ \int (a+b \tan (e+f x)) \sqrt {c+d \tan (e+f x)} \, dx=2\,\mathrm {atanh}\left (\frac {32\,b^2\,d^4\,\sqrt {\frac {b^2\,c}{4\,f^2}-\frac {\sqrt {-b^4\,d^2\,f^4}}{4\,f^4}}\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{\frac {16\,b\,d^4\,\sqrt {-b^4\,d^2\,f^4}}{f^3}+\frac {16\,b\,c^2\,d^2\,\sqrt {-b^4\,d^2\,f^4}}{f^3}}-\frac {32\,c\,d^2\,\sqrt {\frac {b^2\,c}{4\,f^2}-\frac {\sqrt {-b^4\,d^2\,f^4}}{4\,f^4}}\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}\,\sqrt {-b^4\,d^2\,f^4}}{\frac {16\,b\,d^4\,\sqrt {-b^4\,d^2\,f^4}}{f}+\frac {16\,b\,c^2\,d^2\,\sqrt {-b^4\,d^2\,f^4}}{f}}\right )\,\sqrt {-\frac {\sqrt {-b^4\,d^2\,f^4}-b^2\,c\,f^2}{4\,f^4}}-2\,\mathrm {atanh}\left (\frac {32\,b^2\,d^4\,\sqrt {\frac {\sqrt {-b^4\,d^2\,f^4}}{4\,f^4}+\frac {b^2\,c}{4\,f^2}}\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{\frac {16\,b\,d^4\,\sqrt {-b^4\,d^2\,f^4}}{f^3}+\frac {16\,b\,c^2\,d^2\,\sqrt {-b^4\,d^2\,f^4}}{f^3}}+\frac {32\,c\,d^2\,\sqrt {\frac {\sqrt {-b^4\,d^2\,f^4}}{4\,f^4}+\frac {b^2\,c}{4\,f^2}}\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}\,\sqrt {-b^4\,d^2\,f^4}}{\frac {16\,b\,d^4\,\sqrt {-b^4\,d^2\,f^4}}{f}+\frac {16\,b\,c^2\,d^2\,\sqrt {-b^4\,d^2\,f^4}}{f}}\right )\,\sqrt {\frac {\sqrt {-b^4\,d^2\,f^4}+b^2\,c\,f^2}{4\,f^4}}-\mathrm {atanh}\left (\frac {f^3\,\left (\frac {16\,\left (a^2\,d^4-a^2\,c^2\,d^2\right )\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{f^2}+\frac {16\,c\,d^2\,\left (\sqrt {-a^4\,d^2\,f^4}+a^2\,c\,f^2\right )\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{f^4}\right )\,\sqrt {-\frac {\sqrt {-a^4\,d^2\,f^4}+a^2\,c\,f^2}{f^4}}}{16\,\left (a^3\,c^2\,d^3+a^3\,d^5\right )}\right )\,\sqrt {-\frac {\sqrt {-a^4\,d^2\,f^4}+a^2\,c\,f^2}{f^4}}-\mathrm {atanh}\left (\frac {f^3\,\left (\frac {16\,\left (a^2\,d^4-a^2\,c^2\,d^2\right )\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{f^2}-\frac {16\,c\,d^2\,\left (\sqrt {-a^4\,d^2\,f^4}-a^2\,c\,f^2\right )\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{f^4}\right )\,\sqrt {\frac {\sqrt {-a^4\,d^2\,f^4}-a^2\,c\,f^2}{f^4}}}{16\,\left (a^3\,c^2\,d^3+a^3\,d^5\right )}\right )\,\sqrt {\frac {\sqrt {-a^4\,d^2\,f^4}-a^2\,c\,f^2}{f^4}}+\frac {2\,b\,\sqrt {c+d\,\mathrm {tan}\left (e+f\,x\right )}}{f} \]

input
int((a + b*tan(e + f*x))*(c + d*tan(e + f*x))^(1/2),x)
 
output
2*atanh((32*b^2*d^4*((b^2*c)/(4*f^2) - (-b^4*d^2*f^4)^(1/2)/(4*f^4))^(1/2) 
*(c + d*tan(e + f*x))^(1/2))/((16*b*d^4*(-b^4*d^2*f^4)^(1/2))/f^3 + (16*b* 
c^2*d^2*(-b^4*d^2*f^4)^(1/2))/f^3) - (32*c*d^2*((b^2*c)/(4*f^2) - (-b^4*d^ 
2*f^4)^(1/2)/(4*f^4))^(1/2)*(c + d*tan(e + f*x))^(1/2)*(-b^4*d^2*f^4)^(1/2 
))/((16*b*d^4*(-b^4*d^2*f^4)^(1/2))/f + (16*b*c^2*d^2*(-b^4*d^2*f^4)^(1/2) 
)/f))*(-((-b^4*d^2*f^4)^(1/2) - b^2*c*f^2)/(4*f^4))^(1/2) - 2*atanh((32*b^ 
2*d^4*((-b^4*d^2*f^4)^(1/2)/(4*f^4) + (b^2*c)/(4*f^2))^(1/2)*(c + d*tan(e 
+ f*x))^(1/2))/((16*b*d^4*(-b^4*d^2*f^4)^(1/2))/f^3 + (16*b*c^2*d^2*(-b^4* 
d^2*f^4)^(1/2))/f^3) + (32*c*d^2*((-b^4*d^2*f^4)^(1/2)/(4*f^4) + (b^2*c)/( 
4*f^2))^(1/2)*(c + d*tan(e + f*x))^(1/2)*(-b^4*d^2*f^4)^(1/2))/((16*b*d^4* 
(-b^4*d^2*f^4)^(1/2))/f + (16*b*c^2*d^2*(-b^4*d^2*f^4)^(1/2))/f))*(((-b^4* 
d^2*f^4)^(1/2) + b^2*c*f^2)/(4*f^4))^(1/2) - atanh((f^3*((16*(a^2*d^4 - a^ 
2*c^2*d^2)*(c + d*tan(e + f*x))^(1/2))/f^2 + (16*c*d^2*((-a^4*d^2*f^4)^(1/ 
2) + a^2*c*f^2)*(c + d*tan(e + f*x))^(1/2))/f^4)*(-((-a^4*d^2*f^4)^(1/2) + 
 a^2*c*f^2)/f^4)^(1/2))/(16*(a^3*d^5 + a^3*c^2*d^3)))*(-((-a^4*d^2*f^4)^(1 
/2) + a^2*c*f^2)/f^4)^(1/2) - atanh((f^3*((16*(a^2*d^4 - a^2*c^2*d^2)*(c + 
 d*tan(e + f*x))^(1/2))/f^2 - (16*c*d^2*((-a^4*d^2*f^4)^(1/2) - a^2*c*f^2) 
*(c + d*tan(e + f*x))^(1/2))/f^4)*(((-a^4*d^2*f^4)^(1/2) - a^2*c*f^2)/f^4) 
^(1/2))/(16*(a^3*d^5 + a^3*c^2*d^3)))*(((-a^4*d^2*f^4)^(1/2) - a^2*c*f^2)/ 
f^4)^(1/2) + (2*b*(c + d*tan(e + f*x))^(1/2))/f